<?php

namespace api\modules\pooaiV1\models;

use Yii;

/**
 * This is the model class for table "zpooai_pages".
 *
 * @property string $pooai_pages_id
 * @property string $pooai_pages_name
 * @property string $pooai_gall_images_id
 * @property string $pooai_link
 */
class ZpooaiPages extends \yii\db\ActiveRecord
{
    /**
     * @inheritdoc
     */
    public static function tableName()
    {
        return 'zpooai_pages';
    }

    /**
     * @inheritdoc
     */
    public function rules()
    {
        return [
            [['pooai_pages_id'], 'required'],
            [['pooai_pages_id', 'pooai_gall_images_id'], 'string', 'max' => 40],
            [['pooai_pages_name'], 'string', 'max' => 60],
            [['pooai_link'], 'string', 'max' => 255],
            [['pooai_pages_name'], 'unique'],
        ];
    }

    /**
     * @inheritdoc
     */
    public function attributeLabels()
    {
        return [
            'pooai_pages_id' => Yii::t('app', 'Pooai Pages ID'),
            'pooai_pages_name' => Yii::t('app', 'Pooai Pages Name'),
            'pooai_gall_images_id' => Yii::t('app', 'Pooai Gall Images ID'),
            'pooai_link' => Yii::t('app', 'Pooai Link'),
        ];
    }

    /**
     * @inheritdoc
     * @return \api\modules\pooaiV1\models\query\ZpooaiPagesQuery the active query used by this AR class.
     */
    public static function find()
    {
        return new \api\modules\pooaiV1\models\query\ZpooaiPagesQuery(get_called_class());
    }
}
